By design, web page based applications running in a web browser (e.g. Internet Explorer, Firefox), coded using html and JavaScript, only execute JavaScript within the page the user has loaded and only within the content of the browser, which itself exposes a Browser Object Model (BOM) that also gives the JavaScript limited access to some resources on the computing device. That is, the browser interprets and executes the JavaScript in the web page.
Also, traditional electronic application deployment usually takes the form of downloading an install package from a web site, the browser getting involved to ask the user if they really want to download, the download occurring, an installer package being invoked and after several more questions and clicks the user ends up with an application installed.